/*
 * @Author: your name
 * @Date: 2022-03-30 16:30:43
 * @LastEditTime: 2022-06-07 17:13:27
 * @LastEditors: QiuZongXi 897956138@qq.com
 * @Description: 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 * @FilePath: \vue2_cli\src\api\materialSettlement\salesSettlement.js
 */
//    1:物资结算 2:销售结算
import service from '@/utils/request'
// eslint-disable-next-line no-unused-vars
const { httpPostForm, httpPost, httpGet } = service
const request = {
    //获取table页面列表
    getpaymentList (params) {
        return httpPost({
            url: '/materialsettle/salesSettlement/listByEntity',
            params
        })
    },
    //弹窗接口 ↓
    //获取销售合同
    getxsht (params) {
        return httpPost({
            url: '/subcontract/thirdParty/getSalesSettlement',
            params
        })
    },
    //新增物资销售结算
    addwzxsjs (params) {
        return httpPost({
            url: '/materialsettle/salesSettlement/create',
            params
        })
    },
    //修改物资销售结算
    setwzxsjs (params) {
        return httpPost({
            url: '/materialsettle/salesSettlement/update',
            params
        })
    },
    getxsjsbyid (params) {
        return httpGet({
            url: '/materialsettle/salesSettlement/findById',
            params
        })
    },
    //更新物资结算明细
    upadatejsmx (params) {
        return httpPost({
            url: '/materialsettle/salesSettlement/updateList',
            params
        })
    },
    //根据id 获取结算明细
    getjsmxbyid (params) {
        return httpGet({
            url: '/materialsettle/salesSettlement/getListById',
            params
        })
    },
    //根据id 删除销售结算
    deltexsjs (params) {
        return httpGet({
            url: '/materialsettle/salesSettlement/delete',
            params
        })
    },
    //获取指定机构的项目部仓库
    getProjectDepartmentWarehouse (params) {
        return httpGet({
            url: '/material/warehouseManagement/getProjectDepartmentWarehouse',
            params
        })
    },
}

export default request